Field of the Invention
The present invention relates to an information processing apparatus, a method of controlling the same, and a storage medium, and more particularly to an information processing apparatus operated by software, a method of controlling the information processing apparatus, and a storage medium.
Description of the Related Art
Recently, an information processing apparatus realized as an image forming apparatus or the like has come to have more functions. Along with this, the information processing apparatus has become complicated in the system, and time taken to start up the software tends to be increased.
To solve the problems, a technique has been established in which when being switched off, the information processing apparatus is placed in a state (sleep state) where electric power is supplied only to a volatile memory (e.g. a DRAM) in which software is loaded, so that the information processing apparatus can be restarted from the state when the apparatus is switched on next time, to thereby reduce time required for the start-up of the software.
In relation to the above-mentioned technique, there has been disclosed a technique in which a time at which user operation is rarely performed is statistically determined during the sleep state, and the software is rebooted at the time (see e.g. Japanese Patent Laid-Open Publication No. 2006-229509).
However, if a software trouble (e.g. freeze or memory exhaustion) occurs before the information processing apparatus is switched off and brought into the state (sleep state) where only the volatile memory in which software is loaded is supplied with electric power, the operation of switching off and then switching on (rebooting) the information processing apparatus only returns the apparatus to the same troubled state.
As described above, it is difficult for the conventional technique of rebooting software during the sleep mode to recover the apparatus from a state in which software operation is abnormal to a state in which the software operation is normal.
Further, boot time in a recent information processing system tends to increase due to an increase in the number of programs. In order to achieve quick start of such a system, a technique of using a suspend/resume (or hibernation) function has been proposed.
Japanese Patent Laid-Open Publication No. 2005-284491 proposed a technique in which a memory image of each program formed at completion of the start of the system is made ready for use in advance, and is loaded when recovering from the sleep state, whereby time taken from the start to completion of the boot of an application is reduced.
In general, a user is not aware of difference in processing between a start involving initialization of the entire information processing system and a start performed using the resume function, and when the user turns on a power button, one of the two start processes is performed according to a boot setting.
On the other hand, when the user desires to terminate the information processing system, he/she needs to select between shutdown processing and suspend processing according to the situation.
Further, if a change in settings which requires a system reboot is performed in a normal state of the information processing system, the user needs to judge that the change in settings requires a system reboot and execute shutdown processing irrespective of the boot setting.
However, it is very difficult for an ordinary user to perform the above-mentioned judgment. For this reason, even though a change in settings has been performed which requires shutdown, shutdown may not be executed, making it impossible to properly reflect the change in the settings, or shutdown may be performed though unnecessary, making time taken to boot next time unnecessarily longer.